package com.wx.domain.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.wx.domain.dto.AddFormDto;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * <p>Title:      ProjectInfoVo. </p>
 * <p>Description TODO </p>
 * <p>Copyright: Copyright (c) 2016</p>
 * <p>Company:    医百科技有限公司 </p>
 *
 * @author         <a href="xinglinglove1029@163.com"/>杨文生</a>
 * @since      2020/11/23 13:34
 */
@Data
public class ProjectInfoVo implements Serializable {

    private static final long serialVersionUID = 8419961519858813227L;

    @ApiModelProperty(value = "项目id")
    private String projectId;

    /**
     * 项目名称
     */
    @ApiModelProperty(value = "项目名称")
    @NotBlank(message = "项目名称不能为空")
    private String projectName;

    /**
     * 启动时间
     */
    @ApiModelProperty(value = "启动时间")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    private Date startUpDate;

    /**
     * 结束时间
     */
    @ApiModelProperty(value = "结束时间")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    private Date endDate;

    /**
     * 提交时间
     */
    @ApiModelProperty(value = "提交时间")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    private Date submitDate;

    /**
     * 项目所关联的表单集合
     */
    @ApiModelProperty(value = "项目所关联的表单集合")
    @Size( min=1 ,message = "项目所关联的表单集合至少一个")
    private List<AddFormDto> formDtos;

}
